package best.driver.android.Utils;

import android.os.AsyncTask;

public class UIThreadUtil {

    public static void run(final Runnable runnable) {
        AsyncTask<String, String, String> task = new AsyncTask<String, String, String>() {

            @Override
            protected String doInBackground(String... params) {
                return null;
            }
            
            @Override
            protected void onPostExecute(String result) {
                Logger.d("TEST", "onPostExecute");
                if (runnable != null) {
                    runnable.run();
                }
                super.onPostExecute(result);
            }
        };
        task.execute("");
    }
}
